unit UPrincipal;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, uBaseMain, ActnList, Menus, ComCtrls, Buttons, ExtCtrls, jpeg;

type
  TfPrincipal = class(TfBaseMain)
    mniFuncionario: TMenuItem;
    mniFornecedor: TMenuItem;
    mniSepCadastro1: TMenuItem;
    mniProduto: TMenuItem;
    mniPessoa1: TMenuItem;
    mniGrupoProduto: TMenuItem;
    mniMarca: TMenuItem;
    mniUnidadeMedida: TMenuItem;
    mniSepCadastro2: TMenuItem;
    mniPlanoContas: TMenuItem;
    mniRamoAtividade: TMenuItem;
    mniOrgao: TMenuItem;
    mniCentroCusto: TMenuItem;
    mniSepCadastro3: TMenuItem;
    mniUF: TMenuItem;
    Action1: TAction;
    procedure actParametroBDExecute(Sender: TObject);
    procedure FormCreate(Sender: TObject);
    procedure Action1Execute(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  fPrincipal: TfPrincipal;

implementation

uses UDBUtils, UUF;

{$R *.dfm}

procedure TfPrincipal.actParametroBDExecute(Sender: TObject);
begin

  inherited;
  DBConfig.Execute;
  imgBD.Hint := Format( 'Banco de dados: %s', [DBConfig.FullDBName]);
end;

procedure TfPrincipal.FormCreate(Sender: TObject);
begin
  inherited;

  Self.Caption := Application.Title;
  imgBD.Hint := Format( 'Banco de dados: %s', [DBConfig.FullDBName]);
end;

procedure TfPrincipal.Action1Execute(Sender: TObject);
begin
  inherited;
  with TfUF.Create(nil) do
    try
      ShowModal;
    finally
      Release;
    end;

end;

end.
